#include "../../src/common/JsonUtil.h"
#include "../../src/client/RpcClient.h"

using std::cout;
using std::endl;

void callback(const Json::Value &val)
{
    cout << "result = " << val.asInt() << endl;
}

int main(int argc, char const *argv[])
{
    rpc::client::RpcClient client(false, "127.0.0.1", 9090);

    Json::Value params, result;
    params["num1"] = 1;
    params["num2"] = 2;

    if (client.call("Add", params, result))
    {
        ILOG("result: %d", result.asInt());
    }

    return 0;
}
